package br.com.rampage.model.dao;

import org.hibernate.Session;

public class OperationDao implements Dao{

	private Session session;

	public void setSession(Session session) {
		this.session = session;
	}
	
	@Override
	public void persist(Object value){
		session.save(value);
		
	}
	
	@Override
	public void update(Object value){
		session.update(value);
		
	}
	
	@Override
	public void delete(Object value){
		session.delete(value);
	}
	
	@Override
	public Object findById(Integer id,Class classe){
		return	(Class) session.get(classe, id);
	}

	
	
}
